from selenium import webdriver
from selenium import webdriver
from msedge.selenium_tools import Edge, EdgeOptions

import time
# options = EdgeOptions()
# options.use_chromium = True
# options.binary_location = r"C:\xx\Microsoft\EdgeCore\93.0.926.0\msedge.exe" # 浏览器的位置
# driver = Edge(options=options, executable_path=r"D:\xx\Desktop\edgedriver_win64\msedgedriver.exe") # 相应的浏览器的驱动位置
# driver.get("www.baidu.com")
browser = webdriver.Chrome()
browser.get('http://www.baidu.com')

browser.find_element_by_id('kw').send_keys('xxx')
browser.find_element_by_id('su').click()
time.sleep(4)
browser.close()


